package com.huilian.iotbox.client.service.pay;

import com.huilian.iotbox.data.common.ServerResponse;
import com.huilian.iotbox.data.dto.DeviceDto;
import com.huilian.iotbox.data.dto.MemberDto;
import com.huilian.iotbox.data.dto.OrderDto;
import com.huilian.iotbox.data.po.Activity;

import javax.servlet.http.HttpServletRequest;
import java.io.IOException;
import java.security.KeyManagementException;
import java.security.NoSuchAlgorithmException;
import java.security.NoSuchProviderException;
import java.text.ParseException;

/**
 * PayService
 *
 * @Author mineChen
 * @Date 2021/12/20 上午 11:21
 */
public interface PayService {
    void verification(OrderDto orderDto, Long memberId) throws ParseException;

    void deviceVerification(DeviceDto device, OrderDto orderDto) throws ParseException;

    void orderGen(OrderDto orderDto, DeviceDto device, HttpServletRequest request) throws IOException, NoSuchAlgorithmException;

    Object reqPay(OrderDto orderDto, MemberDto memberDto) throws IOException, NoSuchAlgorithmException, NoSuchProviderException, KeyManagementException;

    Object reqDouYinPay(String outTradeNo, int totalAmount, String body) throws IOException;

    ServerResponse reverseScanReqPay(OrderDto orderDto, HttpServletRequest request) throws IOException, NoSuchAlgorithmException, NoSuchProviderException, KeyManagementException;

    void orderGen(OrderDto orderDto, HttpServletRequest request);
}
